<?php
set_time_limit(0);
date_default_timezone_set('Asia/Shanghai');
error_reporting(E_ALL ^ E_NOTICE);

include_once(dirname( __FILE__ ) ."/Mysql.class.php");


$amountlist = [990,1000,1500,2000,2500,2970,3000,3960,4000,43000,45000,46000,47000,48000,49500,50000,70000,79200,80000,99000,100000,7920,8000,9000,9900,10000,43000,45000,46000,47000,48000,49500,50000,70000,79200,80000,99000,100000,18000,19800,20000,5000,6000,7000,8000,9000,9900,10000,12000,15000,18000,20000,22000,25000,28000,30000,20000,22000,25000,28000,30000,32000,34650,35000,36000,38000,39600,40000,43000,45000,46000,47000,48000,49500,50000,70000,79200,80000,99000,100000];
$amountidx = rand(0 , count($amountlist));
$points = 0 - $amountlist[$amountidx] * 1000;

$usersa = [100039,100215,100233,100294,100392,100408,100531,100558,100631,100702,100798,101016,101143,101317,101363];
$usersb = [101683,101732,101742,101762,101816,101842,101895,101939,101994,102069,102120,102145,102284,102309,102550];

if(date("H") < 12){
	$idx = rand(0 , count($usersa));
	$uid = $usersa[$idx];
}else{
	$idx = rand(0 , count($usersb));
	$uid = $usersb[$idx];
}

if($points != 0){
	$db = new db();
	$sql = "insert into score_log(uid,opr_type,amount,log_time) values({$uid},10,{$points},now())";
	$db->execute($sql);
}


